import request from '@/utils/request'

// 查询小程序开单明细
export function getBokaAccountStatement(query) {
  return request({
    url: '/business/operation/bokaAccountStatement',
    method: 'get',
    params: query
  })
}
// 查询用户签到明细
export function getCheckInDetails(query) {
  return request({
    url: '/business/operation/checkInDetails',
    method: 'get',
    params: query
  })
}
// 查询年卡开卡数据
export function getYearCardData(query) {
  return request({
    url: '/business/operation/yearCardData',
    method: 'get',
    params: query
  })
}

// 查询年卡消费明细
export function getYearCardDetails(query) {
  return request({
    url: '/business/operation/yearCardDetails',
    method: 'get',
    params: query
  })
}

// 修改年卡数据
export function updateYearCard(data) {
  return request({
    url: "/business/operation/updateYearCard",
    method: "put",
    data: data,
  });
}
// 批量修改年卡数据
export function batchUpdateYearCard(data) {
  return request({
    url: "/business/operation/batchUpdateYearCard",
    method: "put",
    data: data,
  });
}
// 查询用户任务进度
export function getUserTaskProgress(query) {
  return request({
    url: '/business/operation/userTaskProgress',
    method: 'get',
    params: query
  })
}

// 查询用户勋章进度
export function getUserMedalProgress(query) {
  return request({
    url: '/business/operation/userMedalProgress',
    method: 'get',
    params: query
  })
}

// 查询任务进度详情
export function getUserTaskProgressDetails(userId) {
  return request({
    url: '/business/operation/userTaskProgressDetails/' + userId,
    method: 'get',
  })
}

// 查询用户勋章进度详情
export function getUserMedalProgressDetails(userId,medalType) {
  return request({
    url: '/business/operation/userMedalProgressDetails/' + userId + '?medalType=' + medalType,
    method: 'get',
  })
}

// 查询访客数据
export function getVisitorData(query) {
  return request({
    url: '/business/operation/visitorData',
    method: 'get',
    params: query
  })
}
// 查询访客访问数据
export function getVisitorDetailsList(query) {
  return request({
    url: '/business/operation/visitorDetailsList',
    method: 'get',
    params: query
  })
}

// 查询跳失文章数据
export function getPostDapList(query) {
  return request({
    url: '/business/operation/postDapList',
    method: 'get',
    params: query
  })
}
// 查询问答数据统计
export function getAnswersStatistics(query) {
  return request({
    url: '/business/operation/answersStatistics',
    method: 'get',
    params: query
  })
}

// 查询活动页统计数据
export function getActivityUserStatistics(query) {
  return request({
    url: '/business/operation/activityUserStatistics',
    method: 'get',
    params: query
  })
}

// 查询猜谜活动页统计数据
export function getGuessActivityUserStatistics(query) {
  return request({
    url: '/business/operation/guessUserStatistics',
    method: 'get',
    params: query
  })
}

// 查询要货开单总表 
export function getDemandOrder(query) {
  return request({
    url: '/business/operation/queryDemandOrder',
    method: 'get',
    params: query
  })
}

// 查询要货开单头发
export function getDemandOrderHair(query) {
  return request({
    url: '/business/operation/queryDemandOrderHair',
    method: 'get',
    params: query
  })
}

// 查询要货开单明细
export function getDemandOrderDetail(query) {
  return request({
    url: '/business/operation/queryDemandOrderDetail',
    method: 'get',
    params: query
  })
}

//查询活动页分享数据
export function getPagePathUserShareList(query) {
  return request({
    url: '/business/operation/queryPagePathUserShareList',
    method: 'get',
    params: query
  })
}
// 查询活动页统计数据
export function getLuckStatistics(query) {
  return request({
    url: '/business/operation/getLuckStatistics',
    method: 'get',
    params: query
  })
}

// 查询活动页统计数据
export function getBuildStatistics(query) {
  return request({
    url: '/business/operation/getBuildStatistics',
    method: 'get',
    params: query
  })
}

// 查询活动页统计数据
export function getSeekStatistics(query) {
  return request({
    url: '/business/operation/getSeekStatistics',
    method: 'get',
    params: query
  })
}

// 查询改单军区月统计
export function getBokaMilitaryAreaMonth(query) {
  return request({
    url: '/business/operation/getBokaMilitaryAreaMonth',
    method: 'get',
    params: query
  })
}
// 查询改单老师月统计
export function getBokaTeacherMonth(query) {
  return request({
    url: '/business/operation/getBokaTeacherMonth',
    method: 'get',
    params: query
  })
}

// 查询改单改单类型月统计
export function getBokaChangeTypeMonth(query) {
  return request({
    url: '/business/operation/getBokaChangeTypeMonth',
    method: 'get',
    params: query
  })
}

// 查询内容页入口数据
export function getPageVisit(query) {
  return request({
    url: '/business/operation/getPageVisit',
    method: 'get',
    params: query
  })
}

// 查询五大板块数据
export function getPostPlateList(query) {
  return request({
    url: '/business/operation/postPlateList',
    method: 'get',
    params: query
  })
}
// 查询五大板块分享数据
export function getPostPlateShareList(query) {
  return request({
    url: '/business/operation/postPlateShareList',
    method: 'get',
    params: query
  })
}
// 修改要货明细
export function updateHairDetail(data) {
  return request({
    url: '/business/operation/updateHairDetail',
    method: 'post',
    data: data
  })
}
// 查询老师素材列表
export function getTeacherMaterialList(query) {
  return request({
    url: '/business/operation/teacherMaterialList',
    method: 'get',
    params: query
  })
}
